/**
 * Auto gen via dbpojo-gen.
 */
package com.us.usws.service.cud.impl;

import org.apache.commons.lang3.StringUtils;

import com.us.usws.dao.BaseVideoTypeExtattrDAO;
import com.us.usws.model.flat.base.DOBaseVideoTypeExtattr;
import com.us.usws.service.cud.BaseVideoTypeExtattrCUDService;

/**
 * Service RO impl class
 * @author robot
 */
public class BaseVideoTypeExtattrCUDServiceImpl implements BaseVideoTypeExtattrCUDService {

	/**
	 * DAO instance
	 */
	private BaseVideoTypeExtattrDAO dao = new BaseVideoTypeExtattrDAO();

	/**
	 * Insert one row.
	 */
	@Override
	public String addBaseVideoTypeExtattr(DOBaseVideoTypeExtattr baseVideoTypeExtattr) {
		return dao.insertBaseVideoTypeExtattr(baseVideoTypeExtattr);
	}

	/**
	 * Update by PK.
	 */
	@Override
	public void updateBaseVideoTypeExtattr(DOBaseVideoTypeExtattr baseVideoTypeExtattr) {
		dao.updateBaseVideoTypeExtattr(baseVideoTypeExtattr);
	}

	/**
	 * Delete row by PK.
	 */
	@Override
	public void deleteBaseVideoTypeExtattr(String uid) {
		dao.deleteBaseVideoTypeExtattr(uid);
	}

	@Override
	public void deleteBaseVideoTypeExtattrMore(String uids) {
		if (StringUtils.isNotBlank(uids)) {
			String[] uid = StringUtils.split(uids, ",");
			for (String id : uid) {
				deleteBaseVideoTypeExtattr(id);
			}
		}
	}

}